﻿<%@ Page Language="C#" AutoEventWireup="True" CodeBehind="SecurityPreviewWindow.aspx.cs" 
    Inherits="Medianamik.UI.Web.ModalWindows.SecurityPreviewWindow" 
    MasterPageFile="~/Medianamik/MasterPages/MedianamikModalWindow.Master"
    EnableViewState="false" %>
<%@ Import Namespace="Medianamik.Globalization"%> <%-- Pas de postback = Pas besoin de viewstate --%>

<asp:Content ID="HeaderContentHolder" runat="server" ContentPlaceHolderID="HeaderContentHolder">
<telerik:RadScriptBlock runat="server" ID="scriptBlock">
	<script type="text/javascript">
        //<![CDATA[
        function GetRadWindow()
        {
            var oWindow = null;
            if (window.radWindow) oWindow = window.radWindow;
            else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;
            return oWindow;
        }

        function closeWindow() {
            oWindow.Close();
        }
        //]]>            
	</script>
	</telerik:RadScriptBlock>
</asp:Content>

<asp:Content ID="CenterContent" ContentPlaceHolderID="CenterContent" runat="server">
    <asp:ScriptManager ID="WindowScriptManager" runat="server" />
    <asp:PlaceHolder ID="mainPlaceHolder" runat="server">
        <h2><%=Translator.Translate("Medianamik_SecurityManagement", "SecurityPreviewTitle") %> : <%=CurrentGroup %></h2>
        <p><%=Translator.Translate("Medianamik_SecurityManagement", "SecurityPreviewText") %></p>
        <div class="BlocResume ZoneTexte"><h3><%=Translator.Translate("Medianamik_SecurityManagement", "SecurityPreviewRoleTitle") %></h3>
        <asp:Repeater ID="RoleList" runat="server">
            <HeaderTemplate><ul></HeaderTemplate>
            <ItemTemplate><li><%# Translator.Translate("Medianamik_SecurityManagement", "Role_" + Container.DataItem.ToString()) %></li></ItemTemplate>
            <FooterTemplate></ul></FooterTemplate>
        </asp:Repeater>
        </div>
        <div class="BlocResume"><h3><%=Translator.Translate("Medianamik_SecurityManagement", "SecurityPreviewTypeTitle") %></h3>
        <asp:Repeater ID="TypePermissionList" runat="server">
            <HeaderTemplate><ul></HeaderTemplate>
            <ItemTemplate><li><img src="<%# Eval("TypeIconPath") %>" /><strong><%# Eval("TypeName") %></strong><br /><%# "("+Eval("SecurityName")+")" %></li></ItemTemplate>
			<FooterTemplate></ul></FooterTemplate>
		</asp:Repeater>
		</div>
		<div class="BlocResume TreeViewBox">
			<h3><%=Translator.Translate("Medianamik_SecurityManagement", "SecurityPreviewElementTitle") %></h3>
			<asp:Literal ID="NodePermissionTree" runat="server" />
		</div>
    </asp:PlaceHolder>
    <asp:PlaceHolder ID="denyPlaceHolder" Visible="false" runat="server">
        <p><asp:Literal ID="denyMessage" runat="server" /></p>
    </asp:PlaceHolder>
</asp:Content>